package com.shijie.vo;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.shijie.entity.Submit;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;
import java.time.LocalDateTime;

@Data
@NoArgsConstructor
@AllArgsConstructor
@Builder
public class SubmitVO implements Serializable {

    @JsonFormat(shape = JsonFormat.Shape.STRING)
    private Long submitId;

    private PoolVO poolVO;

    private Submit.Status status;

    private String code;

    private Submit.CodeType codeType;

    private Integer  useMilTime; // ms

    private Integer useKbMemory; // kb

    private String errorMsg;

    @JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime putTime;

}
